<template>
  <div id="Sample">
    <div class="sam-body">
      <div class="sab-header">
        <span>商业住宅老城区Q1满意度调查问卷1</span>
        <div class="sabh-right">
          <i class="el-icon-refresh"></i>
          <i class="el-icon-delete"></i>
          <button>导出</button>
          <button>导入</button>
        </div>
      </div>
      <div class="sab-middle">
        <div class="sabm1">
          <span>选择时间</span>
          <div class="block">
            <el-date-picker v-model="value6" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期">
            </el-date-picker>
          </div>
        </div>
        <div class="sabm2">
          <span>过滤数据</span>
          <el-checkbox-group v-model="checkList">
            <el-checkbox label="重复IP"></el-checkbox>
            <el-checkbox label="重复手机号"></el-checkbox>
          </el-checkbox-group>
          <span class="sabm2-span1">数据来源</span>
          <el-select v-model="savalue" placeholder="请选择数据来源">
            <el-option v-for="saitem in saoptions" :key="saitem.savalue" :label="saitem.salabel" :value="saitem.savalue">

            </el-option>
          </el-select>
          <span class="sabm2-span2">小区</span>
          <input type="text" v-model="villageName" />
          <button class="sabm2-btn">搜索</button>
        </div>
      </div>
      <div class="sab-footer">
        <el-table ref="multipleTable" :data="tableData3" tooltip-effect="dark" border style="width: 100%" height="50vh" @selection-change="handleSelectionChange">
          <el-table-column type="selection" width="55" align="center">
          </el-table-column>
          <el-table-column prop="seeID" label="查看" width="70" align="center">
          	<template slot-scope="scope">
          		<i :class="scope.row.seeID"></i>
          	</template>
          </el-table-column>
          <el-table-column prop="dataSources" label="数据来源" align="center">
          </el-table-column>
          <el-table-column prop="userId" label="用户ID" align="center">
          </el-table-column>
          <el-table-column label="开始答题时间" align="center">
          	<template slot-scope="scope">{{ scope.row.startAnswer }}</template>
          </el-table-column>
          <el-table-column label="结束答题时间" align="center">
            <template slot-scope="scope">{{ scope.row.endAnswer }}</template>
          </el-table-column>
        </el-table>
      </div>
      <div class="sab-page">
        <div class="sp-left">
      		<span>共 {{totalAmount/10}}页</span>
      	</div>
      	<div class="sp-right">
      		<el-pagination
  					background
  					layout="prev, pager, next"
  					:total="totalAmount"
  				>
					</el-pagination>
				</div>
      </div>
    </div>
  </div>
</template>

<script>
  export default {
    data() {
      return {
      	totalAmount: 80,
        villageName: '阳光小区',
        page: 1,
        //element-ui时间组件数据       
        value6: '',
        value7: '',
        //element-ui复选框数据
        checkList: [],
        //数据来源下拉框数据
        saoptions: [{
          savalue: '选项1',
          salabel: '短信'
        }, {
          savalue: '选项2',
          salabel: '彩之云'
        }, {
          savalue: '选项3',
          salabel: '未知'
        }],
        savalue: '',
        //表格内容区域
        tableData3: [{
          seeID: 'el-icon-view',
          dataSources: '阳光小区',
          userId: '001',
          startAnswer: '2018-04-08',
          endAnswer: '2018-05-03',
          name: '王小虎',
          address: '上海市普陀区金沙江路 1518 弄'
        }, {
          seeID: 'el-icon-view',
          dataSources: '阳光小区',
          userId: '002',
          startAnswer: '2018-04-08',
          endAnswer: '2018-05-03',
          name: '王小虎',
          address: '上海市普陀区金沙江路 1518 弄'
        }, {
          seeID: 'el-icon-view',
          dataSources: '阳光小区',
          userId: '003',
          startAnswer: '2018-04-08',
          endAnswer: '2018-05-03',
          name: '王小虎',
          address: '上海市普陀区金沙江路 1518 弄'
        }, {
          seeID: 'el-icon-view',
          dataSources: '阳光小区',
          userId: '004',
          startAnswer: '2018-04-08',
          endAnswer: '2018-05-03',
          name: '王小虎',
          address: '上海市普陀区金沙江路 1518 弄'
        }, {
          seeID: 'el-icon-view',
          dataSources: '阳光小区',
          userId: '005',
          startAnswer: '2018-04-08',
          endAnswer: '2018-05-03',
          name: '王小虎',
          address: '上海市普陀区金沙江路 1518 弄'
        }, {
          seeID: 'el-icon-view',
          dataSources: '阳光小区',
          userId: '006',
          startAnswer: '2018-04-08',
          endAnswer: '2018-05-03',
          name: '王小虎',
          address: '上海市普陀区金沙江路 1518 弄'
        }, {
          seeID: 'el-icon-view',
          dataSources: '阳光小区',
          userId: '007',
          startAnswer: '2018-04-08',
          endAnswer: '2018-05-03',
          name: '王小虎',
          address: '上海市普陀区金沙江路 1518 弄'
        }, {
          seeID: 'el-icon-view',
          dataSources: '阳光小区',
          userId: '008',
          startAnswer: '2018-04-08',
          endAnswer: '2018-05-03',
          name: '王小虎',
          address: '上海市普陀区金沙江路 1518 弄'
        }, {
          seeID: 'el-icon-view',
          dataSources: '阳光小区',
          userId: '009',
          startAnswer: '2018-04-08',
          endAnswer: '2018-05-03',
          name: '王小虎',
          address: '上海市普陀区金沙江路 1518 弄'
        }, {
          seeID: 'el-icon-view',
          dataSources: '阳光小区',
          userId: '010',
          startAnswer: '2018-04-08',
          endAnswer: '2018-05-03',
          name: '王小虎',
          address: '上海市普陀区金沙江路 1518 弄'
        }],
        multipleSelection: []
      }
    },
    methods:{
    	handleSelectionChange(val) {
          this.multipleSelection = val;
      }
    }
  }
</script>

<style scoped="scoped">
  #Sample {
    width: 99%;
    height: 87vh;
    border-top: none;
    position: relative;
    overflow: auto;
  }
  .sam-body .sab-header {
    height: 45px;
    line-height: 45px;
    padding-left: 30px;
    margin-bottom: 10px;
  }
  .sab-header span {
  	color: #333;
  	font-size: 18px;
  }
  .sab-header .sabh-right {
    float: right;
    margin-right: 20px;
  }
  .sab-header .sabh-right i {
    font-size: 20px;
    margin-right: 6px;
  }
  .sab-header .sabh-right i:hover {
    color: rgb(22, 155, 213);
    cursor: pointer;
  }
  .sab-header .sabh-right button {
    height: 28px;
    border: 1px solid #ccc;
    text-align: center;
    padding: 2px 15px;
    border-radius: 5px;
    outline: none;
    background-color: #fff;
  }
  .sab-header .sabh-right button:nth-of-type(1) {
    margin-right: 10px;
  }
  .sab-header .sabh-right button:hover {
    background-color: rgb(22, 155, 213);
    color: #fff;
    cursor: pointer;
  }
  .sam-body .sab-middle {
    margin-left: 30px;
    padding: 2px 0 10px 0;
    height: 70px;
    overflow: hidden;
    position: relative;
  }
  .sam-body .sab-middle span {
    font-size: 14px;
    margin-right: 10px;
  }
  .sam-body .sab-middle .block {
    display: inline-block;
  }
  .sam-body .sab-middle .sabm2 {
    margin-top: 10px;
  }
  .sabm2 .el-checkbox-group {
    display: inline-block;
  }
  .sabm2 .el-checkbox-group .el-checkbox{
  	margin-left: 8px;
  }
  .sabm2 .el-checkbox-group .el-checkbox:nth-child(1){
  	margin-left: 0px;
  }
  .sabm2 .el-checkbox-group .el-checkbox .el-checkbox__label{  
    display: inline-block;
    padding-left: 5px;
    line-height: 19px;
    font-size: 14px;
  }
  .sabm2 .sabm2-span1 {
    margin-left: 28px;
  }
  .sabm2 .el-select{
  	position: relative;
  	width: 160px;
  }
  .sabm2 .sabm2-span2 {
    margin-left: 30px;
  }
  .sabm2 input[type="text"]{
  	display: inline-block;
  	vertical-align: middle;
  	width: 120px;
  	height: 20px;
  	outline: none;
  	padding: 6px 5px;
  	border-radius: 5px;
  	border: 1px solid #ddd;
  	color: #666;
  }
  .sabm2 button{
  	float: right;
  	margin-right: 20px;
  	padding: 2px 25px;
  	border: 1px solid #ccc;
  	background-color: #fff;
  	border-radius: 3px;
  	outline: none;
  	cursor: pointer;
  }
  
  .sam-body .sab-footer {
    margin-left: 30px;
    margin-top: 20px;
    margin-right: 20px;
  }
  /*底部分页区域*/
  .sam-body .sab-page {
    margin-top: 10px;
    margin-left: 40px;
    margin-right: 20px;
  }
  .sab-page span {
    font-size: 14px;
  }
  .sab-page .sp-left {
    float: left;
  }
  .sab-page .sp-right {
    float: right;
  }
  .sab-page .sp-right input[type="text"] {
    height: 25px;
    line-height: 25px;
    width: 60px;
    text-align: center;
    outline: none;
  }
  .sab-page .sp-right span:hover {
    text-decoration: underline;
    cursor: pointer;
  }
</style>